package edgeEntity

import (
	"gitee.com/fierce_wolf/go-fox-edge-common/commEntity"
)

// 全局接口
var (
	Type entityType
)

type entityType struct {
	ChannelEntity            ChannelEntity
	DeviceEntity             DeviceEntity
	OperateEntity            OperateEntity
	OperateMethodEntity      OperateMethodEntity
	ConfigEntity             ConfigEntity
	DeviceModelEntity        DeviceModelEntity
	DeviceTemplateEntity     DeviceTemplateEntity
	DeviceObjInfEntity       DeviceObjInfEntity
	DeviceMapperEntity       DeviceMapperEntity
	DeviceValueEntity        DeviceValueEntity
	DeviceValueExEntity      DeviceValueExEntity
	DeviceValueExTaskEntity  DeviceValueExTaskEntity
	DeviceStatusEntity       DeviceStatusEntity
	DeviceRecordEntity       DeviceRecordEntity
	DeviceObjectEntity       DeviceObjectEntity
	OperateRecordEntity      OperateRecordEntity
	DeviceHistoryEntity      DeviceHistoryEntity
	OperateMonitorTaskEntity OperateMonitorTaskEntity
	ChannelStatusEntity      ChannelStatusEntity
	UserEntity               UserEntity
	UserRoleEntity           UserRoleEntity
	UserPermissionEntity     UserPermissionEntity
	UserMenuEntity           UserMenuEntity
	RepoCompEntity           RepoCompEntity
	IotDeviceModelEntity     IotDeviceModelEntity
	IotTemplateEntity        IotTemplateEntity
	OperateManualTaskEntity  OperateManualTaskEntity
	OperateChannelTaskEntity OperateChannelTaskEntity
	ExtendConfigEntity       ExtendConfigEntity
}

func Register() {
	commEntity.Factory.Register(&Type.ChannelEntity)
	commEntity.Factory.Register(&Type.DeviceEntity)
	commEntity.Factory.Register(&Type.OperateEntity)
	commEntity.Factory.Register(&Type.OperateMethodEntity)
	commEntity.Factory.Register(&Type.ConfigEntity)
	commEntity.Factory.Register(&Type.DeviceModelEntity)
	commEntity.Factory.Register(&Type.DeviceTemplateEntity)
	commEntity.Factory.Register(&Type.DeviceObjInfEntity)
	commEntity.Factory.Register(&Type.DeviceMapperEntity)
	commEntity.Factory.Register(&Type.DeviceValueEntity)
	commEntity.Factory.Register(&Type.DeviceValueExEntity)
	commEntity.Factory.Register(&Type.DeviceStatusEntity)
	commEntity.Factory.Register(&Type.DeviceRecordEntity)
	commEntity.Factory.Register(&Type.DeviceObjectEntity)
	commEntity.Factory.Register(&Type.OperateRecordEntity)
	commEntity.Factory.Register(&Type.DeviceHistoryEntity)
	commEntity.Factory.Register(&Type.OperateMonitorTaskEntity)
	commEntity.Factory.Register(&Type.ChannelStatusEntity)
	commEntity.Factory.Register(&Type.UserEntity)
	commEntity.Factory.Register(&Type.UserRoleEntity)
	commEntity.Factory.Register(&Type.UserPermissionEntity)
	commEntity.Factory.Register(&Type.UserMenuEntity)
	commEntity.Factory.Register(&Type.RepoCompEntity)
	commEntity.Factory.Register(&Type.IotDeviceModelEntity)
	commEntity.Factory.Register(&Type.IotTemplateEntity)
	commEntity.Factory.Register(&Type.OperateManualTaskEntity)
	commEntity.Factory.Register(&Type.OperateChannelTaskEntity)
	commEntity.Factory.Register(&Type.ExtendConfigEntity)
	commEntity.Factory.Register(&Type.DeviceValueExTaskEntity)
}
